package main

import (
	"net/http"
	"fmt"
	"io/ioutil"
)

func main(){

	resp, err := http.Get("http://www.baidu.com")
	if err != nil {
		panic(err)
	}

	defer resp.Body.Close()

	//fmt.Println(resp)
	body, err :=ioutil.ReadAll(resp.Body)
	fmt.Println(string(body))

}